[#include "../common/taglibs.html"/]
<div class="modal-header">
	<button type="button" class="close" data-dismiss="modal" aria-hidden="true"></button>
	<h4 class="modal-title">[@spring.message code="activity.create.title"/]</h4>
</div>

<div class="modal-control">
	[@form.form commandName="createDTO" method="POST" class="form-horizontal form"]
	<input type="hidden" name="format" value="json">
	<div class="modal-body">
		<div class="form-body">
			
			<div class="form-group">
				<label class="col-md-3 control-label">[@spring.message code="activity.create.form.label.code"/]</label>
				<div class="col-md-9">
					[@spring.bind path="code"]
					<input id="${status.expression}" name="${status.expression}" value="${status.value!}" type="text" class="form-control">
					[/@spring.bind]
				</div>
			</div>
			<div class="form-group">
				<label class="col-md-3 control-label">[@spring.message code="activity.create.form.label.name"/]</label>
				<div class="col-md-9">
					[@spring.bind path="name"]
					<input id="${status.expression}" name="${status.expression}" value="${status.value!}" type="text" class="form-control">
					[/@spring.bind]
				</div>
			</div>
			<div class="form-group">
				<label class="col-md-3 control-label">[@spring.message code="activity.create.form.label.caption"/]</label>
				<div class="col-md-9">
					[@spring.bind path="caption"]
					<input id="${status.expression}" name="${status.expression}" value="${status.value!}" type="text" class="form-control">
					[/@spring.bind]
				</div>
			</div>
			<div class="form-group">
				<label class="col-md-3 control-label">[@spring.message code="activity.create.form.label.beginTime"/]</label>
				<div class="col-md-9">
					[@spring.bind path="beginTime"]
					<input id="${status.expression}" name="${status.expression}" value="${status.value!}" type="text" class="form-control" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})">
					[/@spring.bind]
				</div>
			</div>
			<div class="form-group">
				<label class="col-md-3 control-label">[@spring.message code="activity.create.form.label.endTime"/]</label>
				<div class="col-md-9">
					[@spring.bind path="endTime"]
					<input id="${status.expression}" name="${status.expression}" value="${status.value!}" type="text" class="form-control" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})">
					[/@spring.bind]
				</div>
			</div>
			<div class="form-group">
				<label class="col-md-3 control-label">[@spring.message code="activity.create.form.label.prizeType"/]</label>
				<div class="col-md-9">
					[@spring.bind path="prizeTypeCode"]
					<select id="${status.expression}" name="${status.expression}" class="bs-select form-control">
						[#list prizeTypeList as item]
						<option value="${item.code}">
							${item.name}
						</option>
						[/#list]
					</select>
					[/@spring.bind]
				</div>
			</div>
			<div class="form-group">
				<label class="col-md-3 control-label">[@spring.message code="activity.create.form.label.url"/]</label>
				<div class="col-md-9">
					[@spring.bind path="url"]
					<input id="${status.expression}" name="${status.expression}" value="${status.value!}" type="text" class="form-control">
					[/@spring.bind]
				</div>
			</div>
			
		</div>
	</div>
	<div class="modal-footer">
		<button type="button" class="btn default" data-dismiss="modal">[@spring.message code="form.button.close"/]</button>
		<button type="submit" class="btn blue">[@spring.message code="form.button.submit"/]</button>
	</div>
	[/@form.form]
</div>

<script type="text/javascript">

$('#createDTO').validate({
	rules: {
  	},
	messages:{
	}
});

</script>